#include <stdio.h>
#include <conio.h>
#include <math.h>

main(){
	int h,m,s,giaythem;
	printf("Nhap gio: ");
	scanf("%d",&h);
	printf("Nhap phut: ");
	scanf("%d",&m);
	printf("Nhap giay: ");
	scanf("%d",&s);
	printf("So giay cong them: ");
	scanf("%d",&giaythem);
	m=m+(s+giaythem)/60;
	s=(s+giaythem)%60;
	h=(h+m/60)%24;
	m=m%60;
	printf("KQ : %.2d:%.2d:%.2d",h,m,s);
	getch();
}
